package ee.sepp.aui.ui;


import com.vaadin.annotations.Theme;
import com.vaadin.navigator.Navigator;
import com.vaadin.server.VaadinRequest;
import com.vaadin.ui.UI;
import ee.sepp.aui.ui.views.MainView;
import ee.sepp.aui.ui.views.StartView;

@Theme("mytheme")
@SuppressWarnings("serial")
public class MyVaadinUI extends UI
{
	Navigator navigator;

	public static final String MAINVIEW = "main";

    @Override
    protected void init(VaadinRequest request) {
		getPage().setTitle("Navigation Example");
		// Create a navigator to control the views
		navigator = new Navigator(this, this);
		// Create and register the views
		navigator.addView("", new StartView());
		navigator.addView(MAINVIEW, new MainView());
    }
}
